package com.example.wallpaperapp.ui.activity;

import androidx.appcompat.app.AppCompatActivity;

import android.os.Bundle;
import android.view.View;
import android.widget.ImageView;
import android.widget.TextView;
import android.widget.Toast;

import com.example.wallpaperapp.R;
import com.example.wallpaperapp.base.BaseActivity;

public class KnowledgeActivity extends BaseActivity {

    private ImageView back;
    private TextView history;
    private ImageView collection;
    private ImageView download;
    @Override
    protected void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        setContentView(R.layout.activity_knowledge);

        back  =(ImageView) findViewById(R.id.card_return);
        back.setOnClickListener(new View.OnClickListener() {
            @Override
            public void onClick(View v) {
                finish();
            }
        });
        collection=(ImageView)findViewById(R.id.collection);
        collection.setOnClickListener(new View.OnClickListener() {
            @Override
            public void onClick(View v) {
                collection.setImageDrawable(getResources().getDrawable((R.drawable.collection_clicked)));
                Toast.makeText(KnowledgeActivity.this,"收藏成功！请前往收藏查看",Toast.LENGTH_SHORT).show();
            }
        });
        download=(ImageView)findViewById(R.id.download);
        download.setOnClickListener(new View.OnClickListener() {
            @Override
            public void onClick(View v) {
                download.setImageDrawable(getResources().getDrawable((R.drawable.download_clicked)));
                Toast.makeText(KnowledgeActivity.this,"下载成功！请前往相册查看",Toast.LENGTH_SHORT).show();
            }
        });
    }
    @Override
    protected int initLayout() {
        return R.layout.activity_knowledge;
    }

    @Override
    protected void initView() {

    }

    @Override
    protected void initData() {

    }
}